home *** CD-ROM | disk | FTP | other *** search
/ Visual Basic Controls / Visual Basic Controls.iso / vbcontrol / dprogr_1 / dprogr~1.exe / DProgress.frm (.txt) < prev    next >
Encoding:
Visual Basic Form  |  1998-10-20  |  11.8 KB  |  370 lines

  1. VERSION 5.00
  2. Object = "{BEF057CD-6F14-11D1-9A25-00C04FD8DC2E}#1.0#0"; "DProgress.dll"
  3. Begin VB.Form Form1 
  4.    Caption         =   "DameWare Progress Sample"
  5.    ClientHeight    =   3510
  6.    ClientLeft      =   585
  7.    ClientTop       =   690
  8.    ClientWidth     =   7185
  9.    LinkTopic       =   "Form1"
  10.    ScaleHeight     =   3510
  11.    ScaleWidth      =   7185
  12.    Begin DPROGRESSLibCtl.DProgressCtl DProgressCtl10 
  13.       Height          =   375
  14.       Left            =   240
  15.       TabIndex        =   9
  16.       Top             =   2880
  17.       Width           =   4095
  18.       BorderStyle     =   1
  19.       BorderVisible   =   -1  'True
  20.       DrawStyle       =   1
  21.       Appearance      =   0
  22.       ForeColor       =   16711680
  23.       BackColor       =   12648447
  24.       Text            =   "%3i%%"
  25.       ProgressColor   =   65535
  26.       Position        =   0
  27.       SetStep         =   1
  28.       Interval        =   0
  29.       BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851} 
  30.          Name            =   "MS Sans Serif"
  31.          Size            =   8.25
  32.          Charset         =   0
  33.          Weight          =   400
  34.          Underline       =   0   'False
  35.          Italic          =   0   'False
  36.          Strikethrough   =   0   'False
  37.       EndProperty
  38.    End
  39.    Begin DPROGRESSLibCtl.DProgressCtl DProgressCtl9 
  40.       Height          =   375
  41.       Left            =   240
  42.       TabIndex        =   8
  43.       Top             =   2400
  44.       Width           =   4095
  45.       BorderStyle     =   1
  46.       BorderVisible   =   -1  'True
  47.       DrawStyle       =   0
  48.       Appearance      =   0
  49.       ForeColor       =   0
  50.       BackColor       =   16777215
  51.       Text            =   "%3i%%"
  52.       ProgressColor   =   16711680
  53.       Position        =   0
  54.       SetStep         =   1
  55.       Interval        =   0
  56.       BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851} 
  57.          Name            =   "MS Sans Serif"
  58.          Size            =   8.25
  59.          Charset         =   0
  60.          Weight          =   400
  61.          Underline       =   0   'False
  62.          Italic          =   0   'False
  63.          Strikethrough   =   0   'False
  64.       EndProperty
  65.    End
  66.    Begin DPROGRESSLibCtl.DProgressCtl DProgressCtl8 
  67.       Height          =   2775
  68.       Left            =   6360
  69.       TabIndex        =   7
  70.       Top             =   480
  71.       Width           =   495
  72.       BorderStyle     =   1
  73.       BorderVisible   =   -1  'True
  74.       DrawStyle       =   3
  75.       Appearance      =   1
  76.       ForeColor       =   65535
  77.       BackColor       =   0
  78.       Text            =   "%3i%%"
  79.       ProgressColor   =   16776960
  80.       Position        =   0
  81.       SetStep         =   1
  82.       Interval        =   0
  83.       BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851} 
  84.          Name            =   "MS Sans Serif"
  85.          Size            =   8.25
  86.          Charset         =   0
  87.          Weight          =   400
  88.          Underline       =   0   'False
  89.          Italic          =   0   'False
  90.          Strikethrough   =   0   'False
  91.       EndProperty
  92.    End
  93.    Begin DPROGRESSLibCtl.DProgressCtl DProgressCtl7 
  94.       Height          =   2775
  95.       Left            =   5760
  96.       TabIndex        =   6
  97.       Top             =   480
  98.       Width           =   495
  99.       BorderStyle     =   1
  100.       BorderVisible   =   -1  'True
  101.       DrawStyle       =   2
  102.       Appearance      =   1
  103.       ForeColor       =   0
  104.       BackColor       =   16777215
  105.       Text            =   "%3i%%"
  106.       ProgressColor   =   65280
  107.       Position        =   0
  108.       SetStep         =   1
  109.       Interval        =   0
  110.       BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851} 
  111.          Name            =   "MS Sans Serif"
  112.          Size            =   8.25
  113.          Charset         =   0
  114.          Weight          =   400
  115.          Underline       =   0   'False
  116.          Italic          =   0   'False
  117.          Strikethrough   =   0   'False
  118.       EndProperty
  119.    End
  120.    Begin DPROGRESSLibCtl.DProgressCtl DProgressCtl6 
  121.       Height          =   2775
  122.       Left            =   5160
  123.       TabIndex        =   5
  124.       Top             =   480
  125.       Width           =   495
  126.       BorderStyle     =   1
  127.       BorderVisible   =   -1  'True
  128.       DrawStyle       =   1
  129.       Appearance      =   1
  130.       ForeColor       =   0
  131.       BackColor       =   16777215
  132.       Text            =   "%3i%%"
  133.       ProgressColor   =   16711935
  134.       Position        =   0
  135.       SetStep         =   1
  136.       Interval        =   0
  137.       BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851} 
  138.          Name            =   "MS Sans Serif"
  139.          Size            =   8.25
  140.          Charset         =   0
  141.          Weight          =   400
  142.          Underline       =   0   'False
  143.          Italic          =   0   'False
  144.          Strikethrough   =   0   'False
  145.       EndProperty
  146.    End
  147.    Begin DPROGRESSLibCtl.DProgressCtl DProgressCtl5 
  148.       Height          =   2775
  149.       Left            =   4560
  150.       TabIndex        =   4
  151.       Top             =   480
  152.       Width           =   495
  153.       BorderStyle     =   1
  154.       BorderVisible   =   -1  'True
  155.       DrawStyle       =   0
  156.       Appearance      =   1
  157.       ForeColor       =   0
  158.       BackColor       =   16777215
  159.       Text            =   "%3i%%"
  160.       ProgressColor   =   16711680
  161.       Position        =   0
  162.       SetStep         =   1
  163.       Interval        =   0
  164.       BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851} 
  165.          Name            =   "MS Sans Serif"
  166.          Size            =   8.25
  167.          Charset         =   0
  168.          Weight          =   400
  169.          Underline       =   0   'False
  170.          Italic          =   0   'False
  171.          Strikethrough   =   0   'False
  172.       EndProperty
  173.    End
  174.    Begin DPROGRESSLibCtl.DProgressCtl DProgressCtl4 
  175.       Height          =   375
  176.       Left            =   240
  177.       TabIndex        =   3
  178.       Top             =   1920
  179.       Width           =   4095
  180.       BorderStyle     =   1
  181.       BorderVisible   =   -1  'True
  182.       DrawStyle       =   3
  183.       Appearance      =   0
  184.       ForeColor       =   0
  185.       BackColor       =   16777215
  186.       Text            =   "%3i%%"
  187.       ProgressColor   =   65535
  188.       Position        =   0
  189.       SetStep         =   1
  190.       Interval        =   0
  191.       BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851} 
  192.          Name            =   "MS Sans Serif"
  193.          Size            =   8.25
  194.          Charset         =   0
  195.          Weight          =   400
  196.          Underline       =   0   'False
  197.          Italic          =   0   'False
  198.          Strikethrough   =   0   'False
  199.       EndProperty
  200.    End
  201.    Begin DPROGRESSLibCtl.DProgressCtl DProgressCtl3 
  202.       Height          =   375
  203.       Left            =   240
  204.       TabIndex        =   2
  205.       Top             =   1440
  206.       Width           =   4095
  207.       BorderStyle     =   1
  208.       BorderVisible   =   -1  'True
  209.       DrawStyle       =   2
  210.       Appearance      =   0
  211.       ForeColor       =   255
  212.       BackColor       =   12632256
  213.       Text            =   "%3i%%"
  214.       ProgressColor   =   12582912
  215.       Position        =   0
  216.       SetStep         =   1
  217.       Interval        =   0
  218.       BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851} 
  219.          Name            =   "MS Sans Serif"
  220.          Size            =   8.25
  221.          Charset         =   0
  222.          Weight          =   400
  223.          Underline       =   0   'False
  224.          Italic          =   0   'False
  225.          Strikethrough   =   0   'False
  226.       EndProperty
  227.    End
  228.    Begin DPROGRESSLibCtl.DProgressCtl DProgressCtl2 
  229.       Height          =   375
  230.       Left            =   240
  231.       TabIndex        =   1
  232.       Top             =   960
  233.       Width           =   4095
  234.       BorderStyle     =   1
  235.       BorderVisible   =   -1  'True
  236.       DrawStyle       =   1
  237.       Appearance      =   0
  238.       ForeColor       =   33023
  239.       BackColor       =   16777215
  240.       Text            =   "Process is %3i%% complete"
  241.       ProgressColor   =   16711680
  242.       Position        =   0
  243.       SetStep         =   1
  244.       Interval        =   0
  245.       BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851} 
  246.          Name            =   "Times New Roman"
  247.          Size            =   12
  248.          Charset         =   0
  249.          Weight          =   400
  250.          Underline       =   0   'False
  251.          Italic          =   -1  'True
  252.          Strikethrough   =   0   'False
  253.       EndProperty
  254.    End
  255.    Begin DPROGRESSLibCtl.DProgressCtl DProgressCtl1 
  256.       Height          =   375
  257.       Left            =   240
  258.       TabIndex        =   0
  259.       Top             =   480
  260.       Width           =   4095
  261.       BorderStyle     =   1
  262.       BorderVisible   =   -1  'True
  263.       DrawStyle       =   0
  264.       Appearance      =   0
  265.       ForeColor       =   0
  266.       BackColor       =   16777215
  267.       Text            =   "%3i%%"
  268.       ProgressColor   =   255
  269.       Position        =   0
  270.       SetStep         =   1
  271.       Interval        =   0
  272.       BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851} 
  273.          Name            =   "MS Sans Serif"
  274.          Size            =   8.25
  275.          Charset         =   0
  276.          Weight          =   400
  277.          Underline       =   0   'False
  278.          Italic          =   0   'False
  279.          Strikethrough   =   0   'False
  280.       EndProperty
  281.    End
  282. Attribute VB_Name = "Form1"
  283. Attribute VB_GlobalNameSpace = False
  284. Attribute VB_Creatable = False
  285. Attribute VB_PredeclaredId = True
  286. Attribute VB_Exposed = False
  287. Dim bGoingRight As Long
  288. Private Sub DProgressCtl1_OnTimer()
  289.     DProgressCtl1.StepIt
  290.   If DProgressCtl1.Position = 1000 Then
  291.     DProgressCtl1.Interval = 0
  292.     End If
  293. End Sub
  294. Private Sub DProgressCtl10_OnTimer()
  295. Dim lStep As Long
  296. If DProgressCtl10.Position = 100 Then
  297.     bGoingRight = 1
  298. End If
  299. If DProgressCtl10.Position = 0 Then
  300.     bGoingRight = 0
  301. End If
  302. If bGoingRight = 0 Then
  303.     lStep = 1
  304.     lStep = -1
  305. End If
  306.     DProgressCtl10.Position = DProgressCtl10.Position + lStep
  307. End Sub
  308. Private Sub DProgressCtl2_OnTimer()
  309.     DProgressCtl2.StepIt
  310.   If DProgressCtl2.Position = 100 Then
  311.     DProgressCtl2.Interval = 0
  312.     End If
  313. End Sub
  314. Private Sub DProgressCtl3_OnTimer()
  315.     DProgressCtl3.StepIt
  316.   If DProgressCtl3.Position = 100 Then
  317.     DProgressCtl3.Interval = 0
  318.     End If
  319. End Sub
  320. Private Sub DProgressCtl4_OnTimer()
  321.     DProgressCtl4.StepIt
  322.   If DProgressCtl4.Position = 100 Then
  323.     DProgressCtl4.Interval = 0
  324.     End If
  325. End Sub
  326. Private Sub DProgressCtl5_OnTimer()
  327.     DProgressCtl5.StepIt
  328.   If DProgressCtl5.Position = 100 Then
  329.     DProgressCtl5.Interval = 0
  330.     End If
  331. End Sub
  332. Private Sub DProgressCtl6_OnTimer()
  333.     DProgressCtl6.StepIt
  334.   If DProgressCtl6.Position = 100 Then
  335.     DProgressCtl6.Interval = 0
  336.     End If
  337. End Sub
  338. Private Sub DProgressCtl7_OnTimer()
  339.   DProgressCtl7.StepIt
  340.   If DProgressCtl7.Position = 100 Then
  341.     DProgressCtl7.Interval = 0
  342.     End If
  343. End Sub
  344. Private Sub DProgressCtl8_OnTimer()
  345.   DProgressCtl8.StepIt
  346.   If DProgressCtl8.Position = 100 Then
  347.     DProgressCtl8.Interval = 0
  348.     End If
  349. End Sub
  350. Private Sub DProgressCtl9_OnTimer()
  351. Dim RndValue
  352.     RndValue = Int((100 * Rnd) + 1)    ' Generate random value between 1 and 6.
  353.     DProgressCtl9.Position = RndValue
  354. End Sub
  355. Private Sub Form_Load()
  356.     bGoingRight = 1
  357.     DProgressCtl1.SetRange 0, 270
  358.     DProgressCtl1.SetStep = 5
  359.     DProgressCtl1.Interval = 50
  360.     DProgressCtl2.Interval = 25
  361.     DProgressCtl3.Interval = 60
  362.     DProgressCtl4.Interval = 75
  363.     DProgressCtl5.Interval = 30
  364.     DProgressCtl6.Interval = 70
  365.     DProgressCtl7.Interval = 80
  366.     DProgressCtl8.Interval = 55
  367.     DProgressCtl9.Interval = 250
  368.     DProgressCtl10.Interval = 25
  369. End Sub
  370.